<?php

/**
 *  @FileComment            [文件注释内容模板]
 *  @ProjectName             项目名称：shopFrame
 *  @FileName                   文件名称：GoodsTypeAttrGoodsAttrViewModel.class.php
 *  @Author                       yuerengui <596580041@qq.com>
 *  @Date                          2014-10-16 19:01:33
 *  *
 */
class GoodsTypeAttrGoodsAttrViewModel extends ViewModel {

        public $table = 'goods';
        public $view = array(
            'goods_attr' => array('_type' => 'INNER'),
            'type_attr' => array('_type' => 'INNER', '_on' => '__goods_attr__.type_attr_taid=type_attr
.taid'),
            'goods' => array('_type' => 'INNER', '_on' => '__goods_attr__.goods_gid=goods
.gid'),
        );

        public function get_all_data($where = NULL, $group) {
                return $this->group($group)->where($where)->all();
        }

}
